﻿<%@ Page Language="C#" AutoEventWireup="true" CodeFile="list_zjzh.aspx.cs" Inherits="系统管理_list_zjzh" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
    <title>资金账户管理</title>
</head>
<body>
<fieldset>
<legend>管理资金账户</legend>

    <form id="form1" runat="server">
    <div>
        <asp:LinkButton ID="LinkButton1" runat="server" PostBackUrl="~/系统管理/add_zjzh.aspx">添加新项</asp:LinkButton><br />
        <br />
        <asp:GridView ID="GridView1" runat="server" AllowSorting="True" AutoGenerateColumns="False"
            CellPadding="4" DataKeyNames="code" DataSourceID="SqlDataSource1" ForeColor="#333333" OnRowDeleting="GridView1_RowDeleting">
            <RowStyle BackColor="#F7F6F3" ForeColor="#333333" />
            <Columns>
                <asp:TemplateField HeaderText="资金帐号" SortExpression="code">
                    <EditItemTemplate>
                        <asp:Label ID="Label1" runat="server" Text='<%# Eval("code") %>'></asp:Label>
                    </EditItemTemplate>
                    <ItemTemplate>
                        <asp:Label ID="Label1" runat="server" Text='<%# Bind("code") %>'></asp:Label>
                    </ItemTemplate>
                </asp:TemplateField>
                <asp:BoundField DataField="info" HeaderText="描述信息" SortExpression="info" />
                <asp:TemplateField HeaderText="操作" ShowHeader="False">
                    <EditItemTemplate>
                        <asp:LinkButton ID="LinkButton1" runat="server" CausesValidation="True" CommandName="Update"
                            Text="更新"></asp:LinkButton>
                        <asp:LinkButton ID="LinkButton2" runat="server" CausesValidation="False" CommandName="Cancel"
                            Text="取消"></asp:LinkButton>
                    </EditItemTemplate>
                    <ItemTemplate>
                        <asp:LinkButton ID="LinkButton1" runat="server" CausesValidation="False" CommandName="Edit"
                            Text="编辑"></asp:LinkButton>
                        <asp:LinkButton ID="LinkButton2" runat="server" CausesValidation="False" CommandName="Delete"
                            Text="删除"></asp:LinkButton>
                        <asp:LinkButton ID="LinkButton3" runat="server" PostBackUrl='<%# "~/系统管理/list_xgxz.aspx?code="+Eval("code") %>'>管理相关险种</asp:LinkButton>
                    </ItemTemplate>
                </asp:TemplateField>
            </Columns>
            <FooterStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" />
            <PagerStyle BackColor="#284775" ForeColor="White" HorizontalAlign="Center" />
            <EmptyDataTemplate>
                没有数据
            </EmptyDataTemplate>
            <SelectedRowStyle BackColor="#E2DED6" Font-Bold="True" ForeColor="#333333" />
            <HeaderStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" />
            <EditRowStyle BackColor="#999999" />
            <AlternatingRowStyle BackColor="White" ForeColor="#284775" />
        </asp:GridView>
        <asp:SqlDataSource ID="SqlDataSource1" runat="server" ConnectionString="<%$ ConnectionStrings:insurance_dbConnectionString %>"
            DeleteCommand="DELETE FROM [资金账户表] WHERE [code] = @code" InsertCommand="INSERT INTO [资金账户表] ([code], [info]) VALUES (@code, @info)"
            SelectCommand="SELECT * FROM [资金账户表] ORDER BY [code]" UpdateCommand="UPDATE [资金账户表] SET [info] = @info WHERE [code] = @code">
            <DeleteParameters>
                <asp:Parameter Name="code" Type="String" />
            </DeleteParameters>
            <UpdateParameters>
                <asp:Parameter Name="info" Type="String" />
                <asp:Parameter Name="code" Type="String" />
            </UpdateParameters>
            <InsertParameters>
                <asp:Parameter Name="code" Type="String" />
                <asp:Parameter Name="info" Type="String" />
            </InsertParameters>
        </asp:SqlDataSource>
    
    </div>
    </form>
</fieldset>
</body>
</html>
